package com.fept.msgcore.msgserver.protocol.model.option;

import com.fept.msgcore.msgserver.protocol.model.base.ProtocolConstants;

/**
 * Created by Srma on 2/9/2017.
 */
public class NopOption extends BaseOption {

    /**
     *
     */
    private static final long serialVersionUID = -5384583179348712065L;

    public NopOption() {
        this.setType(ProtocolConstants.OPTION_NOP);
        this.setLength(0);
    }

    /**
     *
     * @param type
     * @return
     */
    public static NopOption getNopOption() {
        NopOption nopOption = new NopOption();
        return nopOption;
    }

    /**
     *
     */
    @Override
    public byte[] pack() {
        byte[] optionBytes = new byte[0];

        this.setValue(optionBytes);
        this.setLength(optionBytes.length);
        return super.pack();
    }

    /**
     *
     */
    @Override
    public void unpack(byte[] data, int offset) {
        super.unpack(data, offset);
    }
}
